import request from "./request";


// 查询所有地标
export function getAllLandmarkApi() {
    return request({
        url: '/landmark/getAll',
        method: 'GET',
    })
}

//查询一个
export function getOneByIdApi(id: any) {
    return request({
        url: '/landmark/getById/' + id,
        method: 'get',
    })
}


// 新增地标
export function addLandmarkApi(data: any) {
    return request({
        url: "/landmark/addLandmark",
        method: 'post',
        data
    })
}


// 删除地标
export function deleteApi(id: any) {
    return request({
        url: "/landmark/delete/" + id,
        method: 'DELETE'
    })
}


//修改地标
export function updateApi(params:any ) {
    return request({
        url: "/landmark/update"  ,
        method: 'PUT',
        params
    })
}


//获取距离
export function getDisApi(params:any ) {
    return request({
        url: "/v3/direction/walking"  ,
        method: 'get',
        params
    })
}


